package com.etc.traval.bizimpl;

import java.util.List;

import javax.jws.soap.SOAPBinding.Use;

import com.etc.traval.biz.DiaryBiz;
import com.etc.traval.dao.DiaryDao;
import com.etc.traval.daoimpl.DiaryDaoImpl;
import com.etc.traval.util.JDBCUtil;
import com.etc.travel.entity.Diary;
import com.etc.travel.entity.User;

public class DiaryBizImpl implements DiaryBiz{
	JDBCUtil util=new JDBCUtil();
	DiaryDao dao=new DiaryDaoImpl();

	@Override
	public boolean addDiary(Diary diary) {
		return dao.addDiary(diary);
	}

	@Override
	public boolean deteleDiaryByID(int id) {
		// TODO Auto-generated method stub
		return dao.deteleDiaryByID(id);
	}

	@Override
	public List<Diary> queryDiary(int size, int page) {
		// TODO Auto-generated method stub
		return dao.queryDiary(size, page);
	}

	@Override
	public List<Diary> queryDiaryByUser(User user, int size, int page) {
		// TODO Auto-generated method stub
		return dao.queryDiaryByUser(user, size, page);
	}

	@Override
	public List<Diary> queryLike(String key, int size, int page) {
		// TODO Auto-generated method stub
		return dao.queryLike(key, size, page);
	}

	@Override
	public List<Diary> queryDiaryByPlaceName(String name, int size, int page) {
		// TODO Auto-generated method stub
		return dao.queryDiaryByPlaceName(name, size, page);
	}

	@Override
	public boolean updateDiaryByUserID(String content, int id) {
		// TODO Auto-generated method stub
		return dao.updateDiaryByUserID(content, id);
	}

	@Override
	public Diary queryDiaryById(int id) {
		// TODO Auto-generated method stub
		return dao.queryDiaryById(id);
	}

	@Override
	public int queryDiaryCount() {
		// TODO Auto-generated method stub
		return dao.queryDiaryCount();
	}

	@Override
	public int queryComUserNum() {
		// TODO Auto-generated method stub
		return dao.queryComUserNum();
	}

	@Override
	public List<Diary> queryDiaryByPlaceId(int placeid, int size, int page) {
		// TODO Auto-generated method stub
		return dao.queryDiaryByPlaceId(placeid, size, page);
	}

}
